<!DOCTYPE HTML>
<html>
<head>
	<meta charset="utf-8">
	<meta name="renderer" content="webkit|ie-comp|ie-stand">
	<link rel="Bookmark" href="imgs/favicon.ico"/>
	<link rel="Shortcut Icon" href="imgs/favicon.ico"/>
	<link rel="stylesheet" type="text/css" href="static/h-ui/css/H-ui.min.css"/>
	<link rel="stylesheet" type="text/css" href="static/h-ui.admin/css/H-ui.admin.css"/>
	<link rel="stylesheet" type="text/css" href="lib/Hui-iconfont/1.0.8/iconfont.css"/>
	<link rel="stylesheet" type="text/css" href="static/h-ui.admin/skin/default/skin.css" id="skin"/>
	<link rel="stylesheet" type="text/css" href="static/h-ui.admin/css/style.css"/>
	<link href="lib/webuploader/0.1.5/webuploader.css" rel="stylesheet" type="text/css"/>
	<title>商城</title>
</head>
<body>
<article class="cl pd-20">
	<form class="form form-horizontal" id="form-member-add">
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-3">
				<span class="c-red">*</span> 页面分布：
			</label>
			<div class="formControls col-xs-8 col-sm-8">
				<span class="select-box">
				<select class="select" id="type">
					<option value="1">头部</option>
					<option value="4">头部2</option>
					<option value="3">底部</option>
				</select>
				</span>
			</div>
		</div>
		<div class="row cl" id="load" style="color: red;">
			<label class="form-label col-xs-4 col-sm-3">
				编辑品牌信息
			</label>
			<div class="formControls col-xs-8 col-sm-8">
				(稍等几秒，加载中...)
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-3">
				<span class="c-red">*</span> 品牌封面类型：
			</label>
			<div class="formControls col-xs-8 col-sm-8">
				<span class="select-box">
				<select class="select" id="cover_type" onchange="setCoverType(this.value);">
					<option value="1">图片</option>
					<option value="2">视频</option>
				</select>
				</span>
			</div>
		</div>
		<div class="row cl" style="display: none;" id="imgOut">
			<label class="form-label col-xs-4 col-sm-3">
				品牌封面：
			</label>
			<div class="formControls col-xs-8 col-sm-8" id="big2Out">
				<div style="padding: 5px 0; width: 100px; background: #0088cc; text-align: center; font-size: 12px; color: #fff; border-radius: 5px; position: relative;">上传图片</div>
				<input type="file" id="bigUpload" style="width: 150px; height: 30px; opacity: 0; cursor: pointer; position: relative; top: -25px; left: -20px;" onchange="upload2Image();"/>
				<div id="bigShow" style="margin-top: -20px;">
					<input type="hidden" id="img" value=""/>
				</div>
			</div>
		</div>
		<div class="row cl" style="display: none;" id="videoOut">
			<label class="form-label col-xs-4 col-sm-3">
				品牌封面：
			</label>
			<div class="formControls col-xs-8 col-sm-8" id="bigOut">
				<div style="padding: 5px 0; width: 100px; background: #0088cc; text-align: center; font-size: 12px; color: #fff; border-radius: 5px; position: relative;">上传视频</div>
				<input type="file" id="big2Upload" style="width: 150px; height: 30px; opacity: 0; cursor: pointer; position: relative; top: -25px; left: -20px;" onchange="upload2Video();"/>
				<div id="big2Show" style="margin-top: -20px;"></div>
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-3">
				指定商品：
			</label>
			<div class="formControls col-xs-8 col-sm-8">
				<input type="text" class="input-text" id="gno" placeholder="输入商品编号"/>
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-3">
				视频地址：
			</label>
			<div class="formControls col-xs-8 col-sm-8">
				<input type="text" class="input-text" id="vlink" placeholder="输入视频地址"/>
			</div>
		</div>
		<div class="row cl">
			<label class="form-label col-xs-4 col-sm-3">
				品牌详情：
			</label>
			<div class="formControls col-xs-8 col-sm-8">
				<!-- 加载编辑器的容器 -->
				<script type="text/javascript" charset="utf-8" src="../ueditor/ueditor.config.js"></script>
				<script type="text/javascript" charset="utf-8" src="../ueditor/ueditor.parse.js"></script>
				<script type="text/javascript" charset="utf-8" src="../ueditor/editor_api.js"></script>
				<script type="text/plain" id="myEditor" style="width: 100%; height: 300px;">
					这里我可以写一些输入提示
				</script>
				<script type="text/javascript">
					//初始化百度编辑器
					var ue = UE.getEditor('myEditor',{
						//这里可以选择自己需要的工具按钮名称,此处仅选择如下五个
						// toolbars:[['FullScreen', 'Source', 'Undo', 'Redo','Bold','test']],
						toolbars: [ [
//								'anchor', //锚点
//								'undo', //撤销
//								'redo', //重做
								'bold', //加粗
								'indent', //首行缩进
//                    			'snapscreen', //截图
								'italic', //斜体
								'underline', //下划线
								'strikethrough', //删除线
								'subscript', //下标
								'fontborder', //字符边框
								'superscript', //上标
								'formatmatch', //格式刷
//								'source', //源代码
//								'blockquote', //引用
//								'pasteplain', //纯文本粘贴模式
//								'selectall', //全选
//								'print', //打印
//								'preview', //预览
								'horizontal', //分隔线
								'removeformat', //清除格式
								'time', //时间
								'date', //日期
								'unlink', //取消链接
								'insertrow', //前插入行
								'insertcol', //前插入列
								'mergeright', //右合并单元格
								'mergedown', //下合并单元格
								'deleterow', //删除行
								'deletecol', //删除列
								'splittorows', //拆分成行
								'splittocols', //拆分成列
								'splittocells', //完全拆分单元格
								'deletecaption', //删除表格标题
								'inserttitle', //插入标题
								'mergecells', //合并多个单元格
								'deletetable', //删除表格
								'cleardoc', //清空文档
								'insertparagraphbeforetable', //"表格前插入行"
								'insertcode', //代码语言
								'fontfamily', //字体
								'fontsize', //字号
								'paragraph', //段落格式
//								'simpleupload', //单图上传
//								'insertimage', //多图上传
								'edittable', //表格属性
								'edittd', //单元格属性
								'link', //超链接
//								'emotion', //表情
//								'spechars', //特殊字符
//								'searchreplace', //查询替换
//								'map', //Baidu地图
//								'gmap', //Google地图
//								'insertvideo', //视频
//								'help', //帮助
								'justifyleft', //居左对齐
								'justifyright', //居右对齐
								'justifycenter', //居中对齐
								'justifyjustify', //两端对齐
								'forecolor', //字体颜色
								'backcolor', //背景色
								'insertorderedlist', //有序列表
								'insertunorderedlist', //无序列表
								'fullscreen', //全屏
								'directionalityltr', //从左向右输入
								'directionalityrtl', //从右向左输入
								'rowspacingtop', //段前距
								'rowspacingbottom', //段后距
								'pagebreak', //分页
								'insertframe', //插入Iframe
								'imagenone', //默认
								'imageleft', //左浮动
								'imageright', //右浮动
								'attachment', //附件
								'imagecenter', //居中
//								'wordimage', //图片转存
								'lineheight', //行间距
								'edittip ', //编辑提示
//								'customstyle', //自定义标题
//								'autotypeset', //自动排版
//								'webapp', //百度应用
								'touppercase', //字母大写
								'tolowercase', //字母小写
								'background', //背景
//								'template', //模板
//								'scrawl', //涂鸦
//								'music', //音乐
//								'inserttable', //插入表格
//								'drafts', // 从草稿箱加载
//								'charts', // 图表
								"|",
								"simpleupload",
								"insertimage",
							] ],
//						toolbars: [
//							//fullscreen全屏，source源码，undo撤销，redo重做
//							['fullscreen', 'source', 'undo', 'redo'],
//							//fontsize字体大小，bold加粗，italic斜体，underline下划线，fontborder字符边框，strikethrough删除线，superscript上标，removeformat清除格式，formatmatch格式刷，autotypeset自动排版，blockquote引用，pasteplain纯文本粘贴模式，forecolor字体颜色，backcolor背景色，insertorderedlist有序列表，selectall全选，cleardoc，清空文档，simpleupload单图上传，
//							['fontsize','bold', 'italic', 'underline', 'fontborder', 'strikethrough', 'superscript', 'subscript', 'removeformat', 'formatmatch', 'autotypeset', 'blockquote', 'pasteplain', '|', 'forecolor', 'backcolor', 'insertorderedlist', 'insertunorderedlist', 'selectall', 'cleardoc', 'simpleupload']
//						],

						//focus时自动清空初始化时的内容
						autoClearinitialContent: true,
						//关闭字数统计
						wordCount: false,
						//关闭elementPath
						elementPathEnabled: false,
						//默认的编辑区域高度
						initialFrameHeight: 300,
						//更多其他参数，请参考ueditor.config.js中的配置项
						autoHeightEnabled: false, //固定高度
					})
				</script>
			</div>
		</div>
		<br/><br/>
		<div class="row cl">
			<div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-3">
				<input class="btn btn-primary radius" type="button" value="&nbsp;&nbsp;保 存&nbsp;&nbsp;" onclick="save();"/>
			</div>
		</div>
	</form>
</article>

<!--自定义弹窗-->
<span id="msgPop"></span>
</body>
</html>


<script type="text/javascript" src="lib/jquery/1.9.1/jquery.min.js"></script>
<script type="text/javascript" src="lib/layer/2.4/layer.js"></script>
<script type="text/javascript" src="static/h-ui/js/H-ui.js"></script>
<script type="text/javascript" src="static/h-ui.admin/js/H-ui.admin.page.js"></script>
<script type="text/javascript" src="js/config.js"></script>
<script type="text/javascript" src="js/view.js"></script>
<script type="text/javascript" src="js/brand.js"></script>
<script type="text/javascript">
	var id = getParamByUrl('id');
	var view = 'edit';
	(function () {
	})();
	setTimeout(function(){
		getOne();
	}, 1000);
</script>